<%-- 
    Document   : loanCollectionContent
    Created on : Aug 14, 2011, 11:48:01 AM
    Author     : MacBook
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="sj" uri="/struts-jquery-tags"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>


<div id="searchdiv" style="display: none">
    <s:form id="getsequ" action="get-seq" cssStyle="clear:left;margin-left:1em;float:left;clear:right;font-size:12px;width:20em">
        <script type="text/javascript">
            $(document).ready(function(){
                $('#go').click(function(e){
                    
                    var sequence = $('#search').val();
                    if(sequence==''){
                        alert('Sequence Number is not specified');
                        document.getElementById('getsequ').submit= false;
                    }else if(isNaN(sequence)){
                        alert('Pls enter a valid Sequence Number');
                        document.getElementById('getsequ').submit= false;
                    }else{
                        document.getElementById('getsequ').submit();
                    }
                });
            });

        </script>
        <s:label cssStyle="font-style:italic;font-size:12px;float:left;clear:right">Search by Sequence:</s:label>
        <s:textfield name="sampleseq" id="search" label="Sequence" cssClass="sampleseq" title="Sequence Number" cssStyle="float:left;clear:left"/>
        <sj:submit id="go" button="true" cssClass="ui-state-default" cssStyle="font-size:12px;float:right" value="Search"/>
    </s:form>

    <s:form action="search-coll" cssStyle="float:left;font-size:12px;width:30em;margin-left:3em">
        <s:label cssStyle="font-style:italic;font-size:12px;float:left">Search by Date & Area Code:</s:label>
        <s:textfield name="date" id="date" cssClass="sampleseq" title="Date" label="Date" cssStyle="float:left"/>
        <s:textfield name="areacode" id="areacode" cssClass="sampleseq" title="Area Code" label="Area Code" cssStyle="float:left"/>
        <sj:submit id="go" button="true" cssClass="ui-state-default" cssStyle="margin-left:15em" value="Search"/>
    </s:form>
</div>